Method for controlling virtual object and related apparatus

ABSTRACT

A method for controlling a virtual object and a related apparatus are disclosed. The method includes: displaying a user interface (UI), the UI including a virtual environment image and an interactive panel region, the virtual environment image being an image in which a virtual environment is observed; receiving a preset operation in a target region in the UI, the target region including a region pertaining to the virtual environment image but not pertaining to the interactive panel region; and controlling the virtual object according to the preset operation to perform a corresponding motion in the virtual environment.

CROSS-REFERENCE TO RELATED APPLICATIONS

This application is a continuation application of InternationalApplication No. PCT/CN2020/103006, filed on Jul. 20, 2020, which claimspriority to Chinese Patent Application No. 201910784863.5, entitled“METHOD AND APPARATUS FOR CONTROLLING VIRTUAL OBJECT, DEVICE, ANDMEDIUM” and filed with the China National Intellectual PropertyAdministration on Aug. 23, 2019, the disclosures of which areincorporated by reference in their entireties.

FIELD

The disclosure relates to the field of computers, and in particular, tothe control of a virtual object.

BACKGROUND

In application programs based on a three-dimensional virtualenvironment, for example, in a first-person shooting (FPS) game, a usermay operate a virtual object in a virtual environment to perform motionssuch as walking, running, climbing, shooting, and fighting. Whencontrolling the virtual object to perform different motions, the userneeds to trigger corresponding user interface (UI) controls in a UI.

There are UI controls corresponding to various motions to be performedby a virtual object in a UI, and the UI controls corresponding tovarious motions are located at different positions of the UI. Forexample, direction buttons are located on a left side of the UI, and arunning button is located on a right side of the UI. When the virtualobject performs a relatively large number of motions, a quantity of UIcontrols corresponding to the motions in the UI also increases. The userneeds to memorize the motions or functions corresponding to the UIcontrols as well as the positions corresponding to the UI controls.

SUMMARY

Embodiments of the disclosure provide a method for controlling a virtualobject and a related apparatus, which may resolve the problem in therelated art that when a virtual object is controlled to perform variousmotions, respective user interface (UI) controls corresponding to themotions need to be triggered, making it impossible for a user to quicklycontrol the virtual object to perform various motions.

According to an aspect of an example embodiment of the disclosure, amethod for controlling a virtual object is provided, including:

displaying a user interface (UI), the UI comprising a virtualenvironment image and an interactive panel region, the virtualenvironment image being an image in which a virtual environment isobserved;

receiving a preset operation in a target region in the UI, the targetregion comprising a region pertaining to the virtual environment imagebut not pertaining to the interactive panel region; and

controlling the virtual object according to the preset operation toperform a corresponding motion in the virtual environment.

According to another aspect of an example embodiment of the disclosure,an apparatus for controlling a virtual object is provided, including:

at least one memory configured to store program code; and at least oneprocessor configured to read the program code and operate as instructedby the program code, the program code including:

display code configured to cause the at least one processor to display auser interface (UI), the UI comprising a virtual environment image andan interactive panel region, the virtual environment image being animage in which a virtual environment is observed;

receiving code configured to cause the at least one processor to receivea preset operation in a target region in the UI, the target regioncomprising a region pertaining to the virtual environment image but notpertaining to the interactive panel region; and

control code configured to cause the at least one processor to controlthe virtual object according to the preset operation to perform acorresponding motion in the virtual environment.

According to another aspect of an example embodiment of the disclosure,a computer device is provided, including a processor and a memory, thememory storing at least one instruction, at least one program, a codeset, or an instruction set, and the at least one instruction, the atleast one program, the code set, or the instruction set being loaded andexecuted by the processor to implement the method for controlling avirtual object according to the foregoing aspect.

According to still another aspect of an example embodiment of thedisclosure, a storage medium is provided, configured to store a computerprogram, the computer program being configured to perform the method forcontrolling a virtual object according to the foregoing aspect.

According to still another aspect of an example embodiment of thedisclosure, a computer program product including instructions isprovided, the instructions, when run on a computer, causing the computerto perform the method for controlling a virtual object according to theforegoing aspect.

BRIEF DESCRIPTION OF THE DRAWINGS

To describe technical solutions in example embodiments of the disclosuremore clearly, the following briefly introduces the accompanying drawingsfor describing the example embodiments. The accompanying drawings in thefollowing description show only some embodiments of the disclosure, anda person of ordinary skill in the art may still derive otheraccompanying drawings from these accompanying drawings without creativeefforts.

FIG. 1 is a schematic diagram of an example of an interface ofcontrolling a virtual object to open a sight in a virtual environment.

FIG. 2 is a schematic diagram of an interface of controlling a virtualobject to open a sight according to an example embodiment of thedisclosure.

FIG. 3 is a block diagram of an implementation environment according toan example embodiment of the disclosure.

FIG. 4 is a flowchart of a method for controlling a virtual objectaccording to an example embodiment of the disclosure.

FIG. 5 is a schematic diagram of a camera model corresponding to theperspective of a virtual object according to an example embodiment ofthe disclosure.

FIG. 6 is a schematic diagram of an interface of establishing aCartesian coordinate system in a user interface (UI) according to anexample embodiment of the disclosure.

FIG. 7 is a schematic diagram of an interface of controlling a virtualobject to stand up according to an example embodiment of the disclosure.

FIG. 8 is a schematic diagram of an example of an interface ofcontrolling a virtual object to start a virtual item.

FIG. 9 is a schematic diagram of an interface of controlling a virtualobject to start a virtual item according to an example embodiment of thedisclosure.

FIG. 10 is a schematic diagram of an interface of controlling a virtualobject to throw a virtual item according to an example embodiment of thedisclosure.

FIG. 11 is a flowchart of a method for controlling a virtual object toopen a sight according to an example embodiment of the disclosure.

FIG. 12 is a flowchart of a method for controlling a virtual object toclose a sight according to an example embodiment of the disclosure.

FIG. 13 is a flowchart of a method for controlling a virtual object toopen fire according to an example embodiment of the disclosure.

FIG. 14 is a flowchart of a method for controlling a virtual object tostand up and throw a virtual item according to an example embodiment ofthe disclosure.

FIG. 15 is a block diagram of an apparatus for controlling a virtualobject according to an example embodiment of the disclosure.

FIG. 16 is a schematic structural diagram of an apparatus of a computerdevice according to an example embodiment of the disclosure.

DETAILED DESCRIPTION

To make objectives, technical solutions, and advantages of thedisclosure clearer, the following further describes implementations ofthe disclosure in detail with reference to the accompanying drawings.

First, terms involved in the example embodiments of the disclosure areintroduced as follows:

A virtual environment is displayed (or provided) by an applicationprogram when run on a terminal. The virtual environment may be asimulated environment of a real world, or may be a semi-simulated and/orsemi-fictional environment, or may be a completely fictionalenvironment. The virtual environment may be any one of a two-dimensionalvirtual environment, a 2.5-dimensional virtual environment, and athree-dimensional virtual environment. This is not limited in thedisclosure. A description is made by using an example in which thevirtual environment is a three-dimensional virtual environment in thefollowing embodiments.

A virtual object is a movable object in a virtual environment. Themovable object may be a virtual character, a virtual animal, a cartooncharacter, or the like, such as a character, an animal, a plant, an oildrum, a wall, or a stone or any type of an object displayed in a virtualenvironment (e.g., a three-dimensional virtual environment). In anembodiment, the virtual object is a three-dimensional model createdbased on a skeletal animation technology. Each virtual object has ashape and a size in the three-dimensional virtual environment, andoccupies some space in the three-dimensional virtual environment.

A virtual item is an item that may be used in association with a virtualobject may in a virtual environment. The virtual item includes a virtualweapon used by the virtual object, an accessory corresponding to thevirtual weapon, virtual food, virtual medicine, clothes, ornament, orthe like. The embodiments of the disclosure are described by using anexample in which the virtual item is a virtual weapon. The virtualweapon includes a common firearm such as a handgun, a rifle, or a sniperrifle, a bow and arrow, a crossbow, a pike, a dagger, a sword, a knife,an ax, a bomb, a missile, or the like.

A first-person shooting (FPS) game is a shooting game in which a usermay play from a first-person perspective. A virtual environment image inthe game is an image (e.g., a picture or any graphical representation)in which a virtual environment is observed from a certain perspective(e.g., the perspective of a first virtual object). In the game, at leasttwo virtual objects play in a single-round battle mode in the virtualenvironment. The virtual object escapes attacks by other virtual objectsand dangers (such as a poison gas area and a swamp) in the virtualenvironment to survive in the virtual environment. When the hit point ofthe virtual object in the virtual environment is zero, the life of thevirtual object in the virtual environment ends, and the final virtualobject surviving in the virtual environment wins. In an embodiment, abattle starts when a first client joins the battle, and ends when thelast client exits the battle. Each client may control one or morevirtual objects in the virtual environment. In an embodiment, arenamodes of the battle may include a single-player battle mode, atwo-player team battle mode, or a multi-player team battle mode. Thebattle mode is not limited in the embodiments of the disclosure.

A trigger control is a user interface (UI) control. The UI control isany visual control or element that may be seen in a UI of an applicationprogram, for example, a control such as a picture, an input box, a textbox, a button, or a label. Some UI controls respond to an operation of auser. For example, if the user triggers an attack control correspondingto a handgun, a virtual object is controlled to use the handgun to makean attack.

In the disclosure, when a virtual item is “equipped, carried, orassembled”, it means that a virtual object owns the virtual item, or avirtual object owns an inventory with an inventory slot and the virtualitem is stored in the inventory of the virtual object, or a virtualobject is using the virtual item.

A method provided in the disclosure may be applied to a virtual reality(VR) application program, a three-dimensional map program, a militarysimulation program, an FPS game, a multiplayer online battle arena(MOBA) game, and the like. An application in a game is used as anexample for description in the following embodiments.

A game based on a virtual environment may be formed by a map of one ormore game worlds. The virtual environment in the game simulatesscenarios in the real world. A user may control a virtual obj ect in thegame to perform actions such as walking, running, jumping, shooting,fighting, driving, throwing, standing up, and lying prone in the virtualenvironment, which has relatively high interactivity. In addition, aplurality of users may form a team online to play an arena game. In anapplication program corresponding to a game, UI controls are set in aUI. A user triggers different UI controls to control a virtual object toperform different motions in a virtual environment. For example, theuser triggers UI controls (e.g., direction buttons) corresponding to amovement function to control the virtual object to move in the virtualenvironment. In another example, when the virtual object is using ahandgun, the user triggers a UI control (e.g., a fire button)corresponding to a fire function (using a virtual weapon to make anattack) to control the virtual object to use the handgun to make anattack in the virtual environment. The UI controls are distributed invarious regions in the UI, and the user needs to memorize the functionsof the UI controls and the regions where the UI controls are located, sothat the virtual object may be quickly controlled to performcorresponding motions.

FIG. 1 is a schematic diagram of an example of an interface ofcontrolling a virtual object to open a sight (or line of sight) in avirtual environment. As shown in (a) of FIG. 1, an aiming control 101,an attack control 103, and a moving control 104 are displayed in aninterface 10 of preparing to open a sight. For example, the aimingcontrol 101 is located in a right side region of the interface 10 ofpreparing to open a sight, and is located on a lower side of acorresponding minimap of the virtual environment. In an embodiment,there is one aiming control 101 in the interface 10. In someembodiments, there are two or more aiming controls 101. The quantity andpositions of the aiming controls 101 are not limited in the disclosure.In an embodiment, a user may customize the positions and quantity of theaiming controls 101. For example, the user sets three aiming controls101 in a right side region of the interface 10 of preparing to open asight. In an embodiment, when using a virtual item like a firearm thatneeds to be aimed at a target, the user triggers the aiming control 101to control the virtual object to open a sight 105.

The attack controls 103 are separately located in a left side region anda right side region of the interface 10 of preparing to open a sight,and the attack control 103 located in the left side region of theinterface 10 is located at the upper left of the moving control 104. Inan embodiment, there are two attack controls 103 in the interface 10. Insome embodiments, there may be one or three or more attack controls 103.The quantity and positions of the attack controls 103 are not limited inthe disclosure. In an embodiment, a user may customize the positions andquantity of the attack controls 103. For example, the user sets threeattack controls 103 in a left side region, a right side region, and amiddle region of the interface 10 of preparing to open a sight.

The moving control 104 is located in the left side region of theinterface 10 of preparing to open a sight and is located at the lowerright of the attack control 103. In an embodiment, the user may triggerthe moving control 104 to control the virtual object to move in thevirtual environment.

After the virtual object opens the sight 105, the UI is shown in (b) ofFIG. 1, and a close control 102 is also displayed in an interface 11 ofan opened sight. The close control 102 is located at a position wherethe aiming control 101 is originally located. That is, a display of theaiming control 101 is switched to a display of the close control 102. Inthis case, the sight 105 is opened corresponding to the firearm that isbeing in use. The display position of the firearm is switched from aright side region of the UI to the center of the UI. The sight 105 isdisplayed at the center of the interface 11 of an opened sight, and isin an aiming state. If the user triggers the close control 102, thesight 105 is closed, and the interface 11 of an opened sight is changedto the interface 10 of preparing to open a sight shown in (a) of FIG. 1.

Based on the method provided in this example, a corresponding UI controlneeds to be triggered in order for the virtual object controlled by theuser to perform a corresponding action. For example, the user needs totrigger the aiming control 101 to control the virtual object to open thesight 105. The user further needs to trigger the corresponding closecontrol 102 to control the virtual object to stop the action (e.g., stopopening the sight 105). The steps are relatively complex, and the userneeds to memorize the corresponding functions and positions of the UIcontrols. The user may not recall a UI control corresponding to anaction and a position corresponding to the UI control, resulting in adelay in performing a corresponding action by the virtual object.

The disclosure provides a method for controlling a virtual object. FIG.2 is a schematic diagram of an interface of controlling a virtual objectaccording to an example embodiment of the disclosure.

An example in which a user controls a virtual object to open anaccessory corresponding to a virtual item in a virtual environment isused for description. In an example, the virtual item used by thevirtual object is a sniper rifle, and the accessory corresponding to thevirtual item is a sight 113. Compared with the example in which theaiming control 101 and the close control 102 are displayed in the UI inFIG. 1, no control about opening or closing the sight 113 is displayedin an interface 110 of an opened sight in FIG. 2. The user may use aquick operation to control the virtual object to open the sight 113. Inan embodiment, the quick operation is a double-tap operation. In anembodiment, a target region 131 is provided in the UI, and the targetregion 131 includes a region pertaining to a virtual environment imagebut not pertaining to an interactive panel region 112. For example, thetarget region 131 is a right side region in the UI, and the right sideregion is a region not pertaining to the interactive panel region 112. Alocation of the target region 131 is not limited. In an embodiment,after the user performs the double-tap operation in the target region131, the UI displays the interface 110 of an opened sight, the sight 113of the virtual item (e.g., the sniper rifle) 111 used by the virtualobject is located at the center of the UI and is in an aiming state, andthe sight 113 is opened, which is the same as the effect of opening thesight 105 by tapping the aiming control 101 by the user shown in (a) ofFIG. 1.

In an embodiment, when the user needs to close the sight 113, the usermay use a quick operation to close the sight 113. For example, the quickoperation to close the sight 113 is a double-tap operation. In anembodiment, the target region 131 of closing the sight 113 and thetarget region 131 of opening the sight 113 are the same region ordifferent regions. When the user performs the double-tap operation inthe target region 131, the virtual object is controlled to close thesight 113. In an embodiment, the virtual item (e.g., the sniper rifle)used by the virtual object is changed to a state before the sight 113 isopened.

In an embodiment, the user may set a range of the target region. Forexample, the user sets a circular region with the center of the UI asthe center and a predetermined length (e.g., 10 units of length) as theradius as the target region. The user may control the virtual object toperform a motion corresponding to the quick operation provided that thequick operation is performed within the target region 131. In anembodiment, the quick operation may be at least one of a single-tapoperation, a double-tap operation, a swipe operation, a drag operation,a long-press operation, a double-tap and long-press operation, and atwo-finger swipe operation. In an embodiment, the user may setcorresponding motion controls corresponding to motions of the virtualobject. For example, when the user uses the quick operation to controlthe virtual object, the display of the controls corresponding to themotions is canceled in the UI. Alternatively, the user sets thepositions and quantity of the controls corresponding to the motions. Itwould be understood that the user may perform different quick operationsin the target region 131 to control the virtual object to performcorresponding motions.

FIG. 3 is a structural block diagram of a computer system according toan example embodiment of the disclosure. The computer system 100includes a first terminal 120, a server 140, and a second terminal 160.

An application program supporting a virtual environment is installed andrun on the first terminal 120. The application program may be any one ofa VR application program, a three-dimensional map program, a militarysimulation program, an FPS game, a MOBA game, a multiplayer gunfightsurvival game, and the like. The first terminal 120 is a terminal usedby a first user. The first user uses the first terminal 120 to control avirtual object in a virtual environment to perform motions. The motionsinclude, for example but are not limited to, at least one of bodyposture adjustment, crawling, walking, running, cycling, jumping,driving, shooting, throwing, and using a virtual item. For example, thevirtual object is a virtual character, such as a simulated characterobject or a cartoon character object.

The first terminal 120 is connected to the server 140 by using awireless network or a wired network.

The server 140 includes at least one of one server, a plurality ofservers, a cloud computing platform, and a virtualization center. Forexample, the server 140 includes a processor 144 and a memory 142. Thememory 142 includes a display module 1421, a control module 1422, and areceiving module 1423. The server 140 is configured to provide a backendservice for an application program supporting a three-dimensionalvirtual environment. In an embodiment, the server 140 takes on primarycomputing work, and the first terminal 120 and the second terminal 160take on secondary computing work; alternatively, the server 140 takes onsecondary computing work, and the first terminal 120 and the secondterminal 160 take on primary computing work; alternatively,collaborative computing is performed by using a distributed computingarchitecture among the server 140, the first terminal 120, and thesecond terminal 160.

An application program supporting a virtual environment is installed andrun on the second terminal 160. The application program may be any oneof a VR application program, a three-dimensional map program, a militarysimulation program, an FPS game, a MOBA game, a multiplayer gunfightsurvival game, and the like. The second terminal 160 is a terminal usedby a second user. The second user uses the second terminal 160 tocontrol a virtual object in a virtual environment to perform motions.The motions include, for example but are not limited to, at least one ofbody posture adjustment, crawling, walking, running, cycling, jumping,driving, shooting, throwing, and using a virtual item. For example, thevirtual object is a virtual character, such as a simulated characterobject or a cartoon character object.

In an embodiment, the virtual object controlled by the first user andthe virtual object controlled by the second user are in the same virtualenvironment. In an embodiment, the virtual object controlled by thefirst user and the virtual object controlled by the second user maypertain to the same team or the same organization, and have a friendrelationship with each other or have a temporary communicationpermission.

In an embodiment, the application programs installed on the firstterminal 120 and the second terminal 160 are the same, or theapplication programs installed on the two terminals are the same type ofapplication programs on different control system platforms. The firstterminal 120 may be generally one of a plurality of terminals, and thesecond terminal 160 may be generally one of a plurality of terminals. Inthis embodiment, only the first terminal 120 and the second terminal 160are used as an example for description. The first terminal 120 and thesecond terminal 160 are of the same device type or of different devicetypes. The device type includes, for example but not limited to, atleast one of a smartphone, a tablet computer, an e-book reader, a MovingPicture Experts Group Audio Layer III (MP3) player, a Moving PictureExperts Group Audio Layer IV (MP4) player, a laptop, and a desktopcomputer. The following embodiment is described by using an example inwhich the terminal includes a smartphone.

A person skilled in the art would understand that there may be more orfewer terminals. For example, there may be only one terminal, or theremay be dozens of or hundreds of terminals or more. The quantity and thedevice type of the terminal are not limited in the embodiments of thedisclosure.

FIG. 4 is a flowchart of a method for controlling a virtual objectaccording to an example embodiment of the disclosure. The method isapplicable to the first terminal 120 and/or the second terminal 160 inthe computer system shown in FIG. 3 or another terminal in the computersystem. The method includes the following operations:

Operation 401: Display a UI, the UI including a virtual environmentimage and an interactive panel region, the virtual environment imagebeing an image of observing a virtual environment from the perspectiveof (or around) a virtual object.

The perspective of observing the virtual environment is an observationangle for observation from a first-person perspective or a third-personperspective of the virtual object in the virtual environment. In anembodiment, in the embodiments of the disclosure, the perspective is anangle for observing the virtual object by using a camera model in thevirtual environment.

In an embodiment, the camera model automatically follows the virtualobject in the virtual environment. That is, when a position of thevirtual object in the virtual environment changes, a position of thecamera model following the virtual object in the virtual environmentchanges simultaneously, and the camera model is always within a presetdistance range of the virtual object in the virtual environment. In anembodiment, in the automatic following process, relative positions ofthe camera model and the virtual object remain unchanged.

The camera model is a three-dimensional model located around a virtualobject in a virtual environment. When a first-person perspective isused, the camera model is located near the head of the virtual object orat the head of the virtual object. When a third-person perspective isused, the camera model may be located behind the virtual object andbound to the virtual object, or may be located at any position away fromthe virtual object by a preset distance. The virtual object located inthe virtual environment may be observed from different angles throughthe camera model. In an embodiment, when the third-person perspective isa first-person over-shoulder perspective, the camera model is locatedbehind the virtual object (for example, at the head and shoulders of thevirtual character). In an embodiment, in addition to the first-personperspective and the third-person perspective, the perspective alsoincludes other perspectives, such as a top perspective. When the topperspective is used, the camera model may be located above the head ofthe virtual object. The top perspective is a perspective for observingthe virtual environment with an angle from the air. In an embodiment,the camera model is not actually displayed in the virtual environment.In other words, the camera model is not displayed in the virtualenvironment displayed in the UI.

A description is made by using an example in which the camera model islocated at any position away from the virtual object by a presetdistance. In an embodiment, one virtual object corresponds to one cameramodel, and the camera model may rotate with the virtual object as arotation center. For example, the camera model rotates with any point ofthe virtual object as the rotation center. During rotation, the cameramodel not only rotates in angle, but also deviates in displacement.During rotation, a distance between the camera model and the rotationcenter remains unchanged, that is, the camera model rotates on a surfaceof a sphere with the rotation center as a sphere center. Any point ofthe virtual object may be the head or the torso of the virtual object,or any point around the virtual object. This is not limited in theembodiments of the disclosure. In an embodiment, when the camera modelobserves the virtual object, a center orientation of the perspective ofthe camera model is a direction of a point of the sphere surface wherethe camera model is located pointing to the sphere center.

In an embodiment, the camera model may alternatively observe the virtualobject at a preset angle in different directions of the virtual object.

For example, referring to FIG. 5, a point in a virtual object 11 isdetermined as a rotation center 12, and a camera model rotates aroundthe rotation center 12. In an embodiment, the camera model is providedwith an initial position, and the initial position is a position aboveand behind the virtual object (for example, a position behind the head).For example, as shown in FIG. 5, the initial position is a position 13,and when the camera model rotates to a position 14 or a position 15, aperspective direction of the camera model changes as the camera modelrotates.

In an embodiment, the virtual environment displayed in the virtualenvironment image includes at least one of the following elements: amountain, a plain, a river, a lake, a sea, a desert, a sky, a plant, abuilding, and a vehicle. Herein, the term “picture” used throughout thepresent specification is an inclusive term to denote various forms ofimage information that may be known in the art, such as an “image” and a“frame”, and any form of visual representation of the image information.

In an embodiment, as shown in FIG. 2, the UI includes the interactivepanel region 112. The interactive panel region 112 is provided with UIcontrols that control the virtual object to perform motions, a messagesending control, a voice control, an emoticon control, a settingcontrol, and the like. The foregoing controls are used for a user tocontrol the virtual object to perform corresponding motions in thevirtual environment, or to send a message (for example, including: atext message, a voice message, and/or an emoticon message) to a teammatein the same team, or to set action attributes (for example, a runningspeed) of the virtual object in the virtual environment, or to setattributes (such as sensitivity, an attack range, and lethality of afirearm) of a virtual weapon, or to display a position of the virtualobject controlled by the user in the virtual environment (for example, athumbnail map of the virtual environment is displayed in the UI). Theuser learns a current state of the virtual object instantly through theinteractive panel region 112, and may use the interactive panel region112 at any time to control the virtual object to perform correspondingmotions. In some embodiments, the shape of the interactive panel regionis rectangular or circular, or the shape of the interactive panel regioncorresponds to the shape of the UI controls in the UI. The shape of theinteractive panel region is not limited in the disclosure.

Operation 402: Receive a quick operation in a target region in the UI,the target region including a region pertaining to the virtualenvironment image but not pertaining to the interactive panel region.

In an embodiment, the quick operation includes at least one of adouble-tap operation, a double-tap and long-press operation, atwo-finger horizontal swipe operation, and a two-finger vertical swipeoperation.

In an embodiment, an example in which a region pertaining to the virtualenvironment image is a region A and the interactive panel region is aregion B is used for description, and the target region includes any ofthe following forms:

First, the target region is a region corresponding to the region A.

In this example, the target region includes a region pertaining to thevirtual environment image but not pertaining to the interactive panelregion. For example, in the example embodiment of FIG. 2, a user mayperform the quick operation in a region where UI controls and a minimapare not included, for example, a region between a moving control and anattack control, as the region that pertains to the virtual environmentimage but does not pertain to the interactive panel region.

Second, the target region is a region corresponding to the region A andthe region B.

In this example, the target region includes regions corresponding to thevirtual environment image and the interactive panel region respectively.For example, in the example embodiment of FIG. 2, a user may perform thequick operation in the regions corresponding to the virtual environmentimage and the interactive panel region simultaneously. For example, theuser may perform the quick operation in a region where the UI controlsor the minimap is located or may perform the quick operation in a regionwhere the UI controls or the minimap is not located. That is, the usermay perform the quick operation at any position in the UI 110.

Third, the target region is a region corresponding to the region B and apart of the region A.

In this example, the target region includes a part of a regioncorresponding to the virtual environment image and a regioncorresponding to the interactive panel region. For example, in theexample embodiment of FIG. 2, a user may perform the quick operation inan interactive panel region and/or a right side region of the virtualenvironment image. That is, the user may perform the quick operation ina right side region of the UI 110 and an interactive panel regioncorresponding to UI controls in a left side region of the UI 110. In anembodiment, the part of the region corresponding to the virtualenvironment image may be any region of a left side region, a right sideregion, an upper side region, and a lower side region in the virtualenvironment image.

Fourth, the target region is a region corresponding to the region A anda part of the region B.

In this example, the target region is a region corresponding to thevirtual environment image and a part of a region corresponding to theinteractive panel region. For example, in the example embodiment of FIG.2, a user may perform the quick operation in a region corresponding tothe virtual environment image and/or a right-side interactive panelregion, that is, the user may perform the quick operation in a regionother than a left-side interactive panel region of the UI 110. In anembodiment, the part of the interactive panel region may be any regionof a left-side interactive panel region, a right-side interactive panelregion, an upper-side interactive panel region, and a lower-sideinteractive panel region.

Fifth, the target region is a region corresponding to a part of theregion A and a part of the region B.

In this example, the target region is a region corresponding to a partof a region corresponding to the virtual environment image and a part ofa region corresponding to the interactive panel region. For example, inthe example embodiment of FIG. 2, a user may perform the quick operationin a region corresponding to a left-side virtual environment imageand/or a left-side interactive panel region. That is, the user mayperform the quick operation in a left side region of the UI 110. Forexample, the user may perform the quick operation in a regioncorresponding to a right-side virtual environment image and/or aleft-side interactive panel region. That is, the user may perform thequick operation in a region other than a right-side interactive panelregion and a left-side virtual environment image. The user may performthe quick operation on the moving control and the attack control, or mayperform the quick operation in a region corresponding to the right-sidevirtual environment image.

In an embodiment, based on the expression form of the foregoing targetregion, the UI may not display the interactive panel region, that is,hide the interactive panel region.

FIG. 6 is a schematic diagram of an interface of a target region in a UIaccording to an example embodiment of the disclosure. For example, aCartesian coordinate system is established with the center of a UI 130as the origin. A target region 131 is provided in a right side region ofthe UI 130 and between a first quadrant and a fourth quadrant in theCartesian coordinate system. The shape of the target region 131 may beelliptical, but is not limited thereto. In an example, a user performs adouble-tap operation in the target region 131 to control a virtualobject to open an accessory corresponding to a virtual item.

In an embodiment, the target region 131 may be any region other than aninteractive panel region in the UI 130. For example, the target region131 is an upper side region of the UI 130, referring to a region betweena left-side edge and right-side UI controls of the UI 130.Alternatively, the target region 131 is a region corresponding to aposition of the virtual item used by the virtual object. For example,the target region 131 is a region corresponding to a virtual weapon (asniper rifle) used by the virtual object.

For example, a user performs different quick operations in the targetregion 131 to control the virtual object to perform different motions.For example, the user performs the double-tap operation in the targetregion 131 to control the virtual object to open the accessory (forexample, a sight corresponding to the sniper rifle used by the virtualobject) corresponding to the virtual item.

Operation 403: Control the virtual object according to the quickoperation to perform a corresponding motion in the virtual environment.

In an embodiment, when a body posture of the virtual object meets afirst condition, the virtual object is controlled according to the quickoperation to adjust the body posture in the virtual environment. In anembodiment, the first condition includes that the body posture of thevirtual object is in a first preset state (e.g., squatting state), andthe quick operation includes a two-finger vertical swipe operation. Thevirtual object may perform actions such as running, jumping, climbing,standing up, and crawling in the virtual environment. The body postureof the virtual object in the virtual environment may be lying prone,squatting, standing, sitting, lying, kneeling, and the like. Forillustrative purposes, an example in which the virtual object stands upin the virtual environment is used for description. FIG. 7 is aschematic diagram of an interface of controlling a virtual object tostand up according to an example embodiment of the disclosure.

When the body posture of the virtual object is in a squatting state,because the virtual environment image is an image of observing thevirtual environment from the perspective of the virtual object, a UI 150displays a perspective seen from below, as when the virtual object looksup, for example, an image corresponding to a sky. In an embodiment,fingers of the user swipe upward in the UI 150 at the same time (asshown by the arrow in FIG. 7). With the swipe operation of the user, thevirtual environment image in the UI 150 changes, and the proportion ofan area of the image corresponding to the sky in the UI 150 decreases.The perspective of the virtual object is in a head-down state. The UI150 includes ground and scenery of the virtual environment. The usercontrols the virtual object according to the two-finger vertical swipeoperation to stand up in the virtual environment.

In some embodiments, the user controls the virtual object according tothe two-finger vertical swipe operation to jump or climb in the virtualenvironment, or the user controls the virtual object according to adouble-tap operation or another quick operation (e.g., when the bodyposture of the virtual object in the virtual environment is in thesquatting state) to stand up in the virtual environment. This is notlimited in the disclosure.

In an embodiment, when a use state of a virtual item meets a secondcondition, the virtual object is controlled according to the quickoperation to open an accessory corresponding to the virtual item in thevirtual environment. In an embodiment, the second condition includesthat the virtual item is in an auto-start state, and the quick operationfurther includes a double-tap operation. The auto-start state means thatthe virtual item may start to be used automatically without a triggeroperation. For example, when the sight 113 is opened in FIG. 2, asubmachine gun automatically makes an attack or opens fire withouttriggering an attack control or a fire control by the user. An examplein which the virtual item is a virtual weapon and the accessorycorresponding to the virtual item is a sight (or line of sight in whichthe virtual item is used) is used for description, as shown in FIG. 2.For example, the virtual weapon 111 used by the virtual objectcontrolled by the user is a submachine gun. When the virtual item is inan auto-start state, the user performs a double-tap operation in atarget region to control the virtual object to open the sight 113corresponding to the submachine gun in the virtual environment. Thesubmachine gun is displayed at the center of the UI 110, and the sight113 is also displayed at the center of the UI 110.

In an embodiment, when the virtual item is a virtual weapon, theaccessory corresponding to the virtual item may be a magazine. Forillustrative purposes, an example in which the virtual weapon is afirearm is used for description. When the virtual weapon is in anauto-start state, the user performs a double-tap operation in the targetregion to control the virtual object to install the magazine for thevirtual firearm in the virtual environment.

In some embodiments, the user may control the virtual object accordingto a double-tap operation to install the accessory of the virtual item,or the user controls the virtual object according to a double-tap andlong-press operation or another quick operation to open the accessorycorresponding to the virtual item in the virtual environment. This isnot limited in the disclosure.

In an embodiment, when a use state of a virtual item meets a thirdcondition, the virtual object is controlled according to the quickoperation to start the virtual item in the virtual environment. In anembodiment, the third condition includes that the virtual item is in amanual start state, and the quick operation further includes adouble-tap and long-press operation. The manual start state means thatthe virtual item requires a trigger operation of the user to be started.For example, the user needs to trigger an attack control to control thevirtual object to use the virtual weapon to make an attack. FIG. 8 is aschematic diagram of an example of an interface of controlling a virtualobject to make an attack. Two attack controls 103 are displayed in anattack interface 12, and the two attack controls 103 are located in aleft side region and a right side region of a UI respectively. Forexample, a virtual item used by the virtual object controlled by a useris a submachine gun, and the user needs to trigger at least one attackcontrol of the two attack controls 103 to control the virtual object tomakes an attack (that is, the submachine gun opens fire).

FIG. 9 is a schematic diagram of an interface of controlling a virtualobject to start a virtual item according to an example embodiment of thedisclosure. A target region 131 and an attack control 114 are displayedin an attack interface 170. A user may control the virtual objectaccording to a double-tap and long-press operation in a target region131 to start the virtual item. For illustrative purposes, an example inwhich the virtual item is a sniper rifle and the target region 131 is anelliptical region on a right side of the attack interface 170 is usedfor description. When the user performs the double-tap and long-pressoperation in the target region 131, the virtual object is controlled touse the sniper rifle to make an attack (that is, to open fire). In anembodiment, the user may trigger an attack control 114 to control thevirtual object to use the sniper rifle to make an attack. In anembodiment, the user may set the quantity of the attack controls 114.For example, there are two attack controls 114 in the UI. Alternatively,an application program corresponding to a game sets the quantity of theattack controls 114 by default. Alternatively, a back-end serverintelligently sets the quantity of the attack controls 114 according touse habits and historical records of the user. This is not limited inthe disclosure. In an embodiment, the user may adjust a position of theattack control 114 in the UI. According to an actual game status, theposition of the attack control 114 in the UI is adjusted in real time toprevent the user from visual disturbance caused by the position of theattack control 114.

In some embodiments, the user may control the virtual object accordingto a double-tap and long-press operation to perform a first motion(e.g., run continuously), or the user controls the virtual objectaccording to a double-tap operation or another quick operation toperform a second motion (e.g., start the virtual item) in the virtualenvironment. This is not limited in the disclosure.

In an embodiment, when a use state of a virtual item meets a fourthcondition, the virtual object is controlled according to the quickoperation to throw the virtual item in the virtual environment. In anembodiment, the fourth condition includes that the virtual object ownsthe virtual item, and the quick operation further includes a two-fingerhorizontal swipe operation. When the virtual object owns the virtualitem, it means that the virtual object has assembled the virtual item,the virtual item is located in an inventory slot of the virtual object,or is being used by the virtual object. For illustrative purposes, anexample in which the virtual item is a bomb is used for description.

FIG. 10 is a schematic diagram of an interface of controlling a virtualobject to throw a virtual item according to an example embodiment of thedisclosure. A bomb 115 owned by the virtual object is displayed in aninterface 190. In an embodiment, fingers of the user swipe to the rightin a target region at the same time, and when the user stops swiping,the virtual object is controlled to throw the bomb owned by the virtualobject. In an embodiment, the user may trigger a weapon control 115 tocontrol the virtual object to throw the bomb. In an embodiment, when thevirtual object is in a squatting state, the user controls the virtualobject according to a two-finger horizontal swipe operation to stand upand throw the bomb.

In some embodiments, the user controls the virtual object according to atwo-finger vertical swipe operation to pick up the virtual item in thevirtual environment or to remove the virtual item assembled by thevirtual object, or the user controls the virtual object according to atwo-finger horizontal swipe operation (as shown by the arrow in FIG.10). or another quick operation to throw the virtual item in the virtualenvironment. This is not limited in the disclosure.

As described above, according to example embodiments, a target region isset in a UI, so that without triggering UI controls corresponding to themotions and without memorizing the functions and positions of the UIcontrols, a user may perform a quick operation in the target region tocontrol a virtual object to perform corresponding motions, to controlthe virtual object according to the quick operation to performcorresponding motions in a virtual environment.

FIG. 11 is a flowchart of a method for controlling a virtual object toopen a sight according to an example embodiment of the disclosure. Themethod is applicable to the first terminal 120 and/or the secondterminal 160 in the computer system shown in FIG. 3 or another terminalin the computer system. The method includes the following operations:

Operation 1101: Select an auto-fire state, and receive a double-tapoperation.

For illustrative purposes, an example in which a virtual item is asniper rifle is used for description. A user selects a state of thesniper rifle to be the auto-fire state, or the user sets the sniperrifle to the auto-fire state. That is, when a virtual object is equippedwith the sniper rifle, the sniper rifle is already in the auto-firestate, and no setting is required.

Operation 1102: Determine whether it is the double-tap operation.

For illustrative purposes, an example in which a quick operation ofopening a sight (or a line of sight) corresponding to the virtual itemis a double-tap operation is used for description. After the userperforms the double-tap operation, an application program correspondingto a game determines whether the operation is the double-tap operation.In an embodiment, the application program obtains a time of a first tapoperation and a time of a second tap operation of the user. When a timeinterval between the first tap operation and the second tap operation isless than a time interval threshold, the operation is determined as thedouble-tap operation. For example, the time interval threshold is 500ms. When the time interval between the first tap operation and thesecond tap operation is less than 500 ms, the received operation isdetermined as the double-tap operation.

Operation 1103: Determine whether the double-tap operation is in arotation region.

In some embodiments, a target region is also named as a rotation region.The name of the target region is not limited in the disclosure. In anembodiment, if the region receiving the double-tap operation is within arange of the rotation region, the double-tap operation is determined tobe in the rotation region. For example, the UI is a rectangular regionwith a length of 100 units of length and a width of 50 units of length.In an example, the range of the rotation region is a rectangular regionformed by a length of more than 50 units of length and less than 100units of length, and a width of 50 units of length, that is, a rightside region relative to the center of the UI. In an example embodimentof FIG. 6, a Cartesian coordinate system is established with the centerof the UI as the origin. A region corresponding to a first quadrant anda fourth quadrant of the Cartesian coordinate system is the rotationregion. The target region 131 is within the range of the regioncorresponding to the first quadrant and the fourth quadrant, and theuser may perform quick operations in the target region 131 to controlthe virtual object.

Operation 1104: Perform a sight opening operation.

For illustration, an example in which a virtual item is a sniper rifleis used for description. When the sniper rifle is in the auto-firestate, after the double-tap operation of the user is received in thetarget region, the application program corresponding to the gamecontrols the virtual object to open the sight of the sniper rifle.

FIG. 12 is a flowchart of a method for controlling a virtual object toclose a sight according to an example embodiment of the disclosure. Themethod is applicable to the first terminal 120 and/or the secondterminal 160 in the computer system shown in FIG. 3 or another terminalin the computer system. The method includes the following operations:

Operation 1201: Receive a sight closing operation.

For illustrative purposes, an example in which a virtual item is asniper rifle is used for description. When a user needs to close a sightof the sniper rifle, a quick operation is performed in a rotation regionin a UI, and an application program closes the sight of the sniper rifleaccording to the quick operation of the user.

Operation 1202: Determine whether it is the double-tap operation.

In an example, a time interval threshold is 900 ms. When a time intervalbetween a first tap operation and a second tap operation of the user is500 ms and is less than the time interval threshold, the two tapoperations are determined as a double-tap operation. In an embodiment,if the time interval between the first tap operation and the second tapoperation is ls, the application program records the tap operation as afirst tap event (that is, the two tap operations are not determined as adouble-tap operation), and the user needs to perform two tap operationsagain and operation 1202 is performed by calculating a time intervalbetween two tap operations of a second tap event.

Operation 1203: Determine whether the double-tap operation is in arotation region.

For example, the UI has a length of 100 units of length and a width of50 units of length. In an example, the range of the rotation region is arectangular region formed by a length of 20 units to 30 units of lengthand a width of 45 units of length. When the user performs the double-tapoperation within the range of this region, the application programdetermines that the double-tap operation is in the rotation region.

Operation 1204: Perform the sight closing operation.

In an example, when the sight of the sniper rifle is opened, the userperforms the double-tap operation in the rotation region to control thevirtual object to close the sight of the sniper rifle.

FIG. 13 is a flowchart of a method for controlling a virtual object toopen fire according to an example embodiment of the disclosure. Themethod is applicable to the first terminal 120 and/or the secondterminal 160 in the computer system shown in FIG. 3 or another terminalin the computer system. The method includes the following operations:

Operation 1301: Select manual firing.

In an embodiment, a user may set a use mode of a virtual item to amanual start mode, or the virtual item is already in the manual startmode (e.g., a default setting of the virtual item) when the user selectsthe virtual item. The manual start mode means that the user needs totrigger a corresponding UI control or perform a corresponding operationto control the virtual object to start the virtual item. Forillustrative purposes, an example in which a virtual item is asubmachine gun is used for description. The user selects a firing modeof the submachine gun as manual firing, and when the user triggers afire control or an attack control, the virtual object is controlled touse the submachine gun to make an attack (that is, the submachine gunfires bullets).

Operation 1302: Determine whether it is the double-tap operation.

In an example, a time interval between a first tap operation and asecond tap operation of the user is 300 ms and is less than a timeinterval threshold of 500 ms, the first tap operation and the second tapoperation of the user are determined as the double-tap operation.

Operation 1303: Determine whether the double-tap operation is in arotation region.

For example, the UI has a length of 100 units of length and a width of50 units of length. In an example, the rotation region is a rectangularregion formed by a length of more than 50 units of length and less than100 units of length and a width of 50 units of length, e.g., a rightside region relative to the center of the UI. The user performs thedouble-tap operation in the rotation region.

Operation 1304: Determine whether a long-press operation is received.

After receiving the double-tap operation in the target region, the useralso needs to perform a press operation in the target region (that is,the rotation region). When a duration of the press operation is greaterthan a duration threshold, it is determined that the long-pressoperation is received in the target region. For example, the durationthreshold is 200 ms. When a duration of the press operation of the useris 300 ms and is greater than the duration threshold, the pressoperation performed by the user is determined as the long-pressoperation.

Operation 1305: Perform a firing operation.

After the user performs the double-tap operation and the long-pressoperation in the target region, the virtual object is controlledaccording to the double-tap and long-press operation to perform thefiring operation. In an example, the user performs the double-tap andlong-press operation in the target region to control the virtual objectto use the submachine gun to perform the firing operation.

Operation 1306: Determine whether to stop the long-press operation.

For illustrative purposes, an example in which a virtual item is asubmachine gun is used for description. When the user controls thevirtual object to use the submachine gun to open fire, the submachinegun adjusts a firing time according to a duration of the long-pressoperation of the user. For example, in a firing state, the duration ofthe long-press operation of the user is 3s, and a firing time of thesubmachine gun is 3s according to the duration of the long-pressoperation.

Operation 1307: Perform a fire ceasing operation.

In an embodiment, when the double-tap and long-press operation in thetarget region stops, the virtual object is controlled to close thevirtual item.

In some embodiments, the double-tap and long-press operation is alsonamed as a double-tap operation and a long-press operation. The name ofthe quick operation is not limited in the disclosure. It would beunderstood that the double-tap and long-press operation performed by theuser in the target region is performing the double-tap operation firstand then performing the long-press operation. In a start state of thevirtual item, a duration of the long-press operation is a duration ofthe virtual item in the start state (e.g., a state in which the virtualitem is used). When the long-press operation stops, the virtual item isclosed (e.g., the virtual item stops being used).

FIG. 14 is a flowchart of a method for controlling a virtual objectthrough a two-finger swipe operation according to an example embodimentof the disclosure. The method is applicable to the first terminal 120and/or the second terminal 160 in the computer system shown in FIG. 3 oranother terminal in the computer system. The method includes thefollowing operations:

Operation 1401: Receive a two-finger swipe operation.

A user performs a two-finger swipe operation in a UI. In an embodiment,the two-finger swipe operation includes a two-finger horizontal swipeoperation and a two-finger vertical swipe operation.

Operation 1402: Determine whether two fingers are in a UI at the sametime.

An application program determines whether two contact pointscorresponding to the two fingers of the user are in the UI at the sametime. In an embodiment, if the two contact points are not in the UI atthe same time, a double-tap operation may be determined.

Operation 1403: Determine whether the two fingers are located in a leftside region and a right side region of the UI, respectively.

In an embodiment, a target region includes a first target region and asecond target region. The application program determines whether the twocontact points corresponding to the two fingers are located in the firsttarget region and the second target region respectively. In anembodiment, the contact point corresponding to a left finger of the useris in the first target region (e.g., the left side region of the UI),and the contact point corresponding to a right finger is in the secondtarget region (e.g., the right side region of the UI).

Operation 1404: Determine a swipe displacement of the two fingers.

The application program determines the swipe displacement of the twocontact points corresponding to the two fingers in the UI. In anembodiment, the swipe displacement of the two contact points is ahorizontal swipe displacement or a vertical swipe displacement. Thehorizontal swipe displacement refers to a swipe in a direction parallelto a length direction of the UI. The vertical swipe displacement is aswipe in a direction parallel to a width direction of the UI.

Operation 1404 a: Determine whether a horizontal coordinate displacementof a two-finger swipe reaches a horizontal coordinate displacementthreshold.

For example, a two-finger horizontal swipe operation is used as anexample for description. In an embodiment, when the two fingers of theuser touch the target region in the UI, first start position coordinatesof a first contact point in the first target region and second startposition coordinates of a second contact point in the second targetregion are obtained; when the first contact point and the second contactpoint stop swiping, first end position coordinates of the first contactpoint in the first target region and second end position coordinates ofthe second contact point in the second target region are obtained; andwhen a horizontal coordinate displacement of the first contact point isgreater than a horizontal coordinate displacement threshold and ahorizontal coordinate displacement of the second contact point isgreater than the horizontal coordinate displacement threshold, it isdetermined that the two-finger horizontal swipe operation is received inthe target region. In an example, the horizontal coordinate displacementthreshold is two units of length. The first start position coordinatesof the first contact point are (−1, 1), the second start positioncoordinates are (1, 1), the first end position coordinates of the firstcontact point are (−4, 1), and the second end position coordinates ofthe second contact point are (4, 1). The horizontal coordinatedisplacement of the first contact point and the horizontal coordinatedisplacement of the second contact point are both three units of lengthand are both greater than the horizontal coordinate displacementthreshold (two units of length), the vertical coordinates of the firstcontact point and the vertical coordinates of the second contact pointhave no displacement during swiping of the contact point, and theapplication program determines that the two-finger swipe operation isthe two-finger horizontal swipe operation.

Operation 1404 b: Determine whether a vertical coordinate displacementof the two-finger swipe reaches a vertical coordinate displacementthreshold.

For example, a two-finger vertical swipe operation is used as an examplefor description. In an embodiment, when the two fingers of the usertouch the target region in the UI, first start position coordinates of afirst contact point in the first target region and second start positioncoordinates of a second contact point in the second target region areobtained; when the first contact point and the second contact point stopswiping, first end position coordinates of the first contact point inthe first target region and second end position coordinates of thesecond contact point in the second target region are obtained; and whena vertical coordinate displacement of the first contact point is greaterthan a vertical coordinate displacement threshold and a verticalcoordinate displacement of the second contact point is greater than thevertical coordinate displacement threshold, it is determined that thetwo-finger vertical swipe operation is received in the target region. Inan example, the vertical coordinate displacement threshold is two unitsof length. The first start position coordinates of the first contactpoint are (−1, 1), the second start position coordinates are (1, 1), thefirst end position coordinates of the first contact point are (−1, −3),and the second end position coordinates of the second contact point are(1, −3). The vertical coordinate displacement of the first contact pointand the vertical coordinate displacement of the second contact point areboth four units of length and are both greater than the verticalcoordinate displacement threshold (two units of length), the horizontalcoordinates of the first contact point and the horizontal coordinates ofthe second contact point have no displacement during swiping of thecontact point, and the application program determines that thetwo-finger swipe operation is the two-finger vertical swipe operation.

Operation 1405 a: Control a virtual object to throw a bomb.

In an embodiment, the application program controls, according to thetwo-finger horizontal swipe operation performed by the user, the virtualobject to throw the bomb.

Operation 1405 b: Control the virtual object to cancel bomb throwing.

In an embodiment, when a horizontal coordinate displacement of any onecontact point of the first contact point and the second contact point isless than the horizontal coordinate displacement threshold, theapplication program controls the virtual object to cancel bomb throwing.In an embodiment, when the application program determines that the quickoperation performed by the user is the two-finger swipe operation, ifthe user does not own the virtual item (such as a bomb), the virtualobject is controlled to cancel bomb throwing.

Operation 1406: Determine whether the virtual object is in a firstpreset state, such as a squatting state.

For example, a body posture of the virtual object in the virtualenvironment is in the squatting state.

Operation 1407a: Control the virtual object to switch to a second presetstate, such as to stand up.

For example, when the body posture of the virtual object in the virtualenvironment is in the squatting state, the two-finger vertical swipeoperation controls the virtual object to stand up in the virtualenvironment.

Operation 1407b: Keep the virtual object in an original state.

For example, when the body posture of the virtual object in the virtualenvironment is not in the squatting state, for example, the body postureof the virtual object is in a standing state, the virtual object isstill kept in the standing state after the user performs the two-fingervertical swipe operation.

In an embodiment, the double-tap operation may control the virtualobject to install the accessory of the virtual item, the double-tap andlong-press operation may control the virtual object to perform actionssuch as continuous running and jumping, the two-finger horizontal swipeoperation may control the virtual object to perform actions such aspicking up virtual items, pushing windows open, and opening doors, andthe two-finger vertical swipe operation may control the virtual objectto perform actions such as squatting, lying prone, and rolling.

The foregoing method is described based on a game application scenarioin the foregoing embodiments, and the following is an exampledescription of the foregoing method based on a military simulationapplication scenario.

A simulation technology is a model technology in which a system behavioror process is reflected by using software and hardware through anexperiment of simulating a real environment.

A military simulation program is a program specially constructed formilitary application by using the simulation technology, which performsquantitative analysis on battle elements such as sea, land, and air,weapon equipment performance, battle action, and the like, to accuratelysimulate a battlefield environment, and present a battlefield status,thereby achieving battle system evaluation and decision aids.

In an example, soldiers set up a virtual battlefield on a terminal onwhich the military simulation program is located, and fight in teams.The soldiers control virtual objects in the virtual battlefieldenvironment to perform at least one operation of walking, running,climbing, driving, shooting, throwing, reconnaissance, and close combatin the virtual battlefield environment. The virtual battlefieldenvironment includes at least one natural form of a plain, a mountain, aplateau, a basin, a desert, a river, a lake, a sea, and vegetation, anda place form such as a building, a vehicle, a ruin, and a trainingground. The virtual object includes a virtual character, a virtualanimal, a cartoon character, or the like. Each virtual object owns ashape and a size in a three-dimensional virtual environment, andoccupies some space in the three-dimensional virtual environment.

Based on the foregoing case, in an example, a virtual object acontrolled by a soldier A performs corresponding motions in a virtualenvironment.

As shown in FIG. 7, when a body posture of the virtual object a in thevirtual environment is in a squatting state, the perspective of thevirtual object a is a perspective seen from below, as when the virtualobject looks up, and as such, a virtual environment image corresponds toa sky (or a substantial portion of the virtual environment imagecorresponds to a sky). The soldier A performs a two-finger verticalswipe operation in a target region in a UI of the military simulationprogram. In an embodiment, the target region includes a first targetregion and a second target region. Two fingers of the soldier A are inthe first target region and the second target region respectively. Forexample, a left finger of the soldier A is in the first target region,and a right finger is in the second target region. The left finger andthe right finger of the soldier A swipe upward in the target regionsrespectively at the same time (as shown by the arrow in FIG. 7) tocontrol the virtual object a to stand up in the virtual environment. Inan embodiment, when the body posture of the virtual object a in thevirtual environment is in a standing state, the soldier A performs atwo-finger vertical swipe operation (the swiping direction is oppositeto a direction shown in FIG. 7) in the target region to control thevirtual object a to squat in the virtual environment.

For example, a virtual item used by the virtual object a is a sniperrifle, and the sniper rifle is in an auto-start state. The soldier Aperforms two tap operations in a target region 131 in the UI of themilitary simulation program (as shown in FIG. 2). When a time intervalbetween a first tap operation and a second tap operation is less than atime interval threshold, the military simulation program determines thatthe two tap operations are a double-tap operation. The double-tapoperation is performed in the target region 131, and the soldier A mayopen a sight corresponding to the sniper rifle according to thedouble-tap operation. In an embodiment, after the sight is opened, thesoldier A may close the sight corresponding to the sniper rifleaccording to the double-tap operation in the target region.

For example, a virtual item used by the virtual object a is a submachinegun, and the submachine gun is in a manual start state. The soldier Aperforms a double-tap and long-press operation in the target region 131in the UI of the military simulation program (as shown in FIG. 6). Themilitary simulation program determines whether the two tap operations ofthe soldier A are a double-tap operation. If the two tap operations arethe double-tap operation, the military simulation program continues todetermine whether the press operation of the soldier A is a long-pressoperation. When a duration of the press operation of the soldier A isgreater than a duration threshold, it is determined that a quickoperation in the target region 131 is the double-tap and long-pressoperation. The military simulation program controls the virtual object aaccording to the double-tap and long-press operation to start thesubmachine gun (that is, to use the submachine gun to open fire as shownin FIG. 9). In an embodiment, when the soldier A stops the long-pressoperation, the military simulation program controls the virtual object ato close a firing function of the submachine gun, and a duration of thelong-press operation is a firing duration of the submachine gun.

For example, a virtual item used by the virtual obj ect a is a bomb, andthe bomb is owned by the virtual object a. The soldier A performs atwo-finger horizontal swipe operation in a target region in a UI of themilitary simulation program. In an embodiment, the target regionincludes a first target region and a second target region. Two fingersof the soldier A are in the first target region and the second targetregion respectively. For example, a left finger of the soldier A is inthe first target region, and a right finger is in the second targetregion. The left finger and the right finger of the soldier A swipe tothe right in the target regions respectively at the same time (as shownby the arrow in FIG. 10) to control the virtual object a to throw thebomb. In an embodiment, when the virtual object a is in a building inthe virtual environment, the soldier A may control the virtual object aaccording to two-finger horizontal swipe operation to open doors andwindows. Alternatively, when there are virtual items in the virtualenvironment, the soldier A may control the virtual object a according tothe two-finger horizontal swipe operation to pick up the virtual itemsin the virtual environment.

Based on the above, in the embodiments of the disclosure, the foregoingmethod for controlling a virtual object is applied to a militarysimulation program, thereby improving battle efficiency, and helping tofacilitate cooperation among soldiers.

The following is an apparatus embodiment of the disclosure. For detailsnot described in detail in the apparatus embodiment, reference may bemade to corresponding record in the foregoing method embodiments.Details are not described herein again.

FIG. 15 is a schematic structural diagram of an apparatus forcontrolling a virtual object according to an example embodiment of thedisclosure. The apparatus may be implemented as all or a part of theterminal by using software, hardware, or a combination thereof. Theapparatus includes: a display module 1510, a receiving module 1520, acontrol module 1530, and an obtaining module 1540. The display module1510 and the receiving module 1530 are optional modules.

The display module 1510 is configured to display a UI, the UI includinga virtual environment image and an interactive panel region, the virtualenvironment image being an image of observing a virtual environment fromthe perspective of a virtual object.

The receiving module 1520 is configured to receive a quick operation ina target region in the UI, the target region including a regionpertaining to the virtual environment image but not pertaining to theinteractive panel region.

The control module 1530 is configured to control the virtual objectaccording to the quick operation to perform a corresponding motion inthe virtual environment.

In an example embodiment, the control module 1530 is further configuredto control, when a body posture of the virtual object meets a firstcondition, the virtual object according to the quick operation to adjustthe body posture in the virtual environment.

In an example embodiment, the first condition includes that the bodyposture of the virtual object is in a squatting state; the quickoperation includes a two-finger vertical swipe operation; the receivingmodule 1520 is further configured to receive the two-finger verticalswipe operation in the target region; and the control module 1530 isfurther configured to control, when the body posture of the virtualobject is in a first preset state, such as the squatting state, thevirtual object according to the two-finger vertical swipe operation toswitch from the first preset state (e.g., squatting state) to a secondpreset state (e.g., standing state) in the virtual environment.

In an example embodiment, the target region includes a first targetregion and a second target region; the obtaining module 1540 isconfigured to obtain first start position coordinates of a first contactpoint in the first target region and second start position coordinatesof a second contact point in the second target region; the obtainingmodule 1540 is further configured to obtain, when the first contactpoint and the second contact point stop swiping, first end positioncoordinates of the first contact point in the first target region andsecond end position coordinates of the second contact point in thesecond target region; and the receiving module 1520 is furtherconfigured to determine, when a vertical coordinate displacement of thefirst contact point is greater than a vertical coordinate displacementthreshold and a vertical coordinate displacement of the second contactpoint is greater than the vertical coordinate displacement threshold,that the two-finger vertical swipe operation is received in the targetregion.

In an example embodiment, the control module 1530 is further configuredto control, when a use state of a virtual item meets a second condition,the virtual object according to the quick operation to open an accessorycorresponding to the virtual item in the virtual environment; or thecontrol module 1530 is further configured to control, when a use stateof a virtual item meets a third condition, the virtual object accordingto the quick operation to start the virtual item in the virtualenvironment; or the control module 1530 is further configured tocontrol, when a use state of a virtual item meets a fourth condition,the virtual object according to the quick operation to throw the virtualitem in the virtual environment.

In an example embodiment, the second condition includes that the virtualitem is in an auto-start state; the quick operation further includes adouble-tap operation; the receiving module 1520 is further configured toreceive the double-tap operation in the target region; and the controlmodule 1530 is further configured to control, when a first virtual itemis in the auto-start state, the virtual object according to thedouble-tap operation to open a sight corresponding to the first virtualitem in the virtual environment.

In an example embodiment, the obtaining module 1540 is furtherconfigured to obtain a time of a first tap operation and a time of asecond tap operation in the target region; and the receiving module 1510is further configured to determine, when a time interval between thefirst tap operation and the second tap operation is less than a timeinterval threshold, that the double-tap operation is received in thetarget region.

In an example embodiment, the third condition includes that the virtualitem is in a manual start state; the quick operation further includes adouble-tap and long-press operation; the receiving module 1510 isfurther configured to receive the double-tap and long-press operation inthe target region; and the control module 1530 is further configured tocontrol, when a second virtual item is in a manual start state, thevirtual object according to the double-tap and long-press operation tostart the second virtual item in the virtual environment.

In an example embodiment, the receiving module 1510 is furtherconfigured to receive a press operation in the target region after thedouble-tap operation in the target region is received; and determine,when a duration of the press operation is greater than a durationthreshold, that the double-tap and long-press operation is received inthe target region.

In an example embodiment, the control module 1530 is further configuredto control, when the double-tap and long-press operation in the targetregion stops, the virtual object to close the virtual item.

In an example embodiment, the fourth condition includes that the virtualobject owns the virtual item; the quick operation further includes atwo-finger horizontal swipe operation; the receiving module 1510 isfurther configured to receive the two-finger horizontal swipe operationin the target region; and the control module 1530 is further configuredto control, when the virtual object owns a third virtual item, thevirtual object according to the two-finger horizontal swipe operation tothrow the third virtual item in the virtual environment.

In an example embodiment, the target region includes a first targetregion and a second target region; the obtaining module 1540 is furtherconfigured to obtain first start position coordinates of a first contactpoint in the first target region and second start position coordinatesof a second contact point in the second target region; the obtainingmodule 1540 is further configured to obtain, when the first contactpoint and the second contact point stop swiping, first end positioncoordinates of the first contact point in the first target region andsecond end position coordinates of the second contact point in thesecond target region; and the receiving module 1510 is furtherconfigured to determine, when a horizontal coordinate displacement ofthe first contact point is greater than a horizontal coordinatedisplacement threshold and a horizontal coordinate displacement of thesecond contact point is greater than the horizontal coordinatedisplacement threshold, that the two-finger horizontal swipe operationis received in the target region.

FIG. 16 shows a structural block diagram of a computer device 1600according to an example embodiment of the disclosure. The computerdevice 1600 may be a portable mobile terminal, such as a smartphone, atablet computer, an MP3 player, or an MP4 player. The computer device1600 may be further referred to as another name such as user equipmentor a portable terminal.

Generally, the computer device 1600 includes a processor 1601 and amemory 1602.

The processor 1601 may include one or more processing cores. Forexample, the processor 1601 may be a 4-core processor or an 8-coreprocessor. The processor 1601 may be implemented in at least onehardware form of a digital signal processor (DSP), a field-programmablegate array (FPGA), and a programmable logic array (PLA). The processor1601 may alternatively include a main processor and a coprocessor. Themain processor is configured to process data in an active state, alsoreferred to as a central processing unit (CPU). The coprocessor is alow-power processor configured to process data in a standby state. Insome embodiments, the processor 1601 may be integrated with a graphicsprocessing unit (GPU). The GPU is configured to be responsible forrendering and drawing content that a display needs to display. In someembodiments, the processor 1601 may further include an artificialintelligence (AI) processor. The AI processor is configured to process acomputing operation related to machine learning.

The memory 1602 may include one or more computer-readable storage media.The computer-readable storage medium may be tangible and non-transient.The memory 1602 may further include a high-speed random access memoryand a non-volatile memory, for example, one or more disk storage devicesor flash memory devices. In some embodiments, the non-transientcomputer-readable storage medium in the memory 1602 is configured tostore at least one instruction. The at least one instruction is executedby the processor 1601 to perform the method for controlling a virtualobj ect provided in the disclosure.

In some embodiments, the computer device 1600 may further include aperipheral interface 1603 and at least one peripheral. Specifically, theperipheral includes at least one of a radio frequency (RF) circuit 1604,a touch display screen 1605, a camera 1606, an audio circuit 1607, apositioning assembly 1608, and a power supply 1609.

The peripheral interface 1603 may be configured to connect at least oneperipheral related to input/output (I/O) to the processor 1601 and thememory 1602. In some embodiments, the processor 1601, the memory 1602,and the peripheral interface 1603 are integrated on the same chip orcircuit board. In some other embodiments, any one or two of theprocessor 1601, the memory 1602, and the peripheral interface 1603 maybe implemented on a separate chip or the circuit board. This is notlimited in this embodiment.

The RF circuit 1604 is configured to receive and transmit an RF signal,which is also referred to as an electromagnetic signal. The RF circuit1604 communicates with a communication network and other communicationdevices through the electromagnetic signal. The RF circuit 1604 convertsan electric signal into an electromagnetic signal for transmission, orconverts a received electromagnetic signal into an electric signal. Inan embodiment, the RF circuit 1604 includes an antenna system, an RFtransceiver, one or more amplifiers, a tuner, an oscillator, a digitalsignal processor, a codec chip set, a subscriber identity module card,and the like. The RF circuit 1604 may communicate with another terminalby using at least one wireless communication protocol. The wirelesscommunication protocol includes, but is not limited to, a world wideweb, a metropolitan area network, an intranet, generations of mobilecommunication networks (2G, 3G, 4G, and 5G), a wireless local areanetwork and/or a wireless fidelity (Wi-Fi) network. In some embodiments,the RF circuit 1604 may further include a circuit related to a nearfield communication (NFC) circuit. This is not limited in thedisclosure.

The touch display screen 1605 is configured to display an UI. The UI mayinclude a graph, text, an icon, a video, and any combination thereof.The touch display screen 1605 also has a capability of collecting atouch signal on or above a surface of the touch display screen 1605. Thetouch signal may be used as a control signal to be inputted to theprocessor 1601 for processing. The touch display screen 1605 isconfigured to provide a virtual button and/or a virtual keyboard, whichis also referred to as a soft button and/or a soft keyboard. In someembodiments, there is one touch display screen 1605, disposed on a frontpanel of the computer device 1600. In some other embodiments, there maybe at least two touch display screens 1605, respectively disposed ondifferent surfaces of the computer device 1600 or designed in a foldableshape. In still some other embodiments, the touch display screen 1605may be a flexible display screen, disposed on a curved surface or afolded surface of the computer device 1600. Even, the touch displayscreen 1605 may be further set in a non-rectangular irregular pattern,namely, a special-shaped screen. The touch display screen 1605 may bemade of a material such as a liquid crystal display (LCD) or an organiclight-emitting diode (OLED).

A camera component 1606 is configured to collect an image or a video. Inan embodiment, the camera component 1606 includes a front-facing cameraand a rear-facing camera. Generally, the front-facing camera isconfigured to implement a video call or self-portrait. The rear-facingcamera is configured to capturing a picture or a video. In someembodiments, there are at least two rear-facing cameras, each of whichis any one of a main camera, a depth of field camera and a wide-anglecamera, so as to implement a background blurring function by fusing themain camera and the depth of field camera, and panoramic shooting and VRshooting functions by fusing the main camera and the wide-angle camera.In some embodiments, the camera component 1606 may further include aflash. The flash may be a single-color-temperature flash, or may be adouble-color-temperature flash. The double-color-temperature flashrefers to a combination of a warm-light flash and a cold-light flash,and may be used for light compensation under different colortemperatures.

The audio circuit 1607 is configured to provide an audio interfacebetween a user and the computer device 1600. The audio circuit 1607 mayinclude a microphone and a speaker. The microphone is configured toacquire sound waves of a user and an environment, and convert the soundwaves into electrical signals and input the electrical signals into theprocessor 1601 for processing, or input the electrical signals into theRF circuit 1604 to implement speech communication. For the purpose ofstereo sound collection or noise reduction, there may be a plurality ofmicrophones, respectively disposed at different parts of the computerdevice 1600. The microphone may further be an array microphone or anomni-directional acquisition type microphone. The speaker is configuredto convert electrical signals from the processor 1601 or the RF circuit1604 into sound waves. The speaker may be a conventional thin-filmspeaker or a piezoelectric ceramic speaker. When the speaker is thepiezoelectric ceramic speaker, the speaker may not only convert anelectrical signal into sound waves audible to a human being, but alsoconvert an electrical signal into sound waves inaudible to the humanbeing for ranging and other purposes. In some embodiments, the audiocircuit 1607 may also include an earphone jack.

The positioning component 1608 is configured to determine a currentgeographic location of the computer device 1600 through positioning, toimplement navigation or a location based service (LBS). The positioningcomponent 1608 may be a positioning assembly based on the GlobalPositioning System (GPS) of the United States, the China's BeidouNavigation Satellite System (BDS), or the Galileo system of Russia.

The power supply 1609 is configured to supply power to components in thecomputer device 1600. The power supply 1609 may be an alternatingcurrent, a direct current, a primary battery, or a rechargeable battery.When the power supply 1609 includes a rechargeable battery, therechargeable battery may be a wired rechargeable battery or a wirelessrechargeable battery. The wired rechargeable battery is a batterycharged through a wired circuit, and the wireless rechargeable batteryis a battery charged through a wireless coil. The rechargeable batterymay be further configured to support a fast charge technology.

In some embodiments, the computer device 1600 further includes one ormore sensors 1610. The one or more sensors 1610 include, for example butare not limited to, an acceleration sensor 1611, a gyroscope sensor1612, a pressure sensor 1613, a fingerprint sensor 1614, an opticalsensor 1615, and a proximity sensor 1616.

The acceleration sensor 1611 may detect accelerations on threecoordinate axes of a coordinate system established by the computerdevice 1600. For example, the acceleration sensor 1611 may be configuredto detect components of gravity acceleration on the three coordinateaxes. The processor 1601 may control, according to a gravityacceleration signal collected by the acceleration sensor 1611, the touchdisplay screen 1605 to display the UI in a frame view or a portraitview. The acceleration sensor 1611 may be further configured to collectmotion data of a game or a user.

The gyroscope sensor 1612 may detect a body direction and a rotationangle of the computer device 1600. The gyroscope sensor 1612 maycooperate with the acceleration sensor 1611 to collect a 3D action bythe user on the computer device 1600. The processor 1601 may implementthe following functions according to the data collected by the gyroscopesensor 1612: motion sensing (such as changing the UI according to a tiltoperation of the user), image stabilization during shooting, gamecontrol, and inertial navigation.

The pressure sensor 1613 may be disposed on a side frame of the computerdevice 1600 and/or a lower layer of the touch display screen 1605. Whenthe pressure sensor 1613 is disposed at the side frame of the computerdevice 1600, a holding signal of the user on the computer device 1600may be detected, and left/right hand identification and a quickoperation may be performed according to the holding signal. When thepressure sensor 1613 is disposed at the lower layer of the touch displayscreen 1605, an operable control in the UI interface may be controlledaccording to a pressure operation of the user on the touch displayscreen 1605. The operable control includes at least one of a buttoncontrol, a scroll-bar control, an icon control, and a menu control.

The fingerprint sensor 1614 is configured to collect a fingerprint of auser to identify the identity of the user according to the collectedfingerprint. When identifying that the identity of the user is a trustedidentity, the processor 1601 authorizes the user to perform relatedsensitive operations. The sensitive operations include: unlocking ascreen, viewing encryption information, downloading software, paying andchanging a setting, and the like. The fingerprint sensor 1614 may bedisposed on a front face, a back face, or a side face of the computerdevice 1600. When a physical button or a vendor logo is disposed on thecomputer device 1600, the fingerprint sensor 1614 may be integratedtogether with the physical button or the vendor logo.

The optical sensor 1615 is configured to collect ambient lightintensity. In an embodiment, the processor 1601 may control displaybrightness of the touch display screen 1605 according to the ambientlight intensity collected by the optical sensor 1615. Specifically, whenthe ambient light intensity is relatively high, the display brightnessof the touch display screen 1605 is increased. When the ambient lightintensity is relatively low, the display brightness of the touch displayscreen 1605 is decreased. In another embodiment, the processor 1601 mayfurther dynamically adjust a camera parameter of the camera component1606 according to the ambient light intensity collected by the opticalsensor 1615.

The proximity sensor 1616, also referred to as a distance sensor, may bedisposed on the front surface of the computer device 1600. The proximitysensor 1616 is configured to collect a distance between a front face ofthe user and the front surface of the computer device 1600. In anembodiment, when the proximity sensor 1616 detects that the distancebetween the front face of the user and the front face of the computerdevice 1600 is gradually decreased, the processor 1601 controls thetouch display screen 1605 to switch from a screen-on state to ascreen-off state. When the proximity sensor 1616 detects that thedistance between the front face of the user and the front face of thecomputer device 1600 is gradually increased, the processor 1601 controlsthe touch display screen 1605 to switch from the screen-off state to thescreen-on state.

A person skilled in the art would understand that the structure shown inFIG. 16 does not constitute any limitation on the computer device 1600,and the computer device may include more components or fewer componentsthan those shown in the figure, or some components may be combined, or adifferent component deployment may be used.

The disclosure further provides a computer device. The computer deviceincludes a processor and a memory. The memory stores at least oneinstruction, at least one program, a code set, or an instruction set.The at least one instruction, the at least one program, the code set, orthe instruction set is loaded and executed by the processor to implementthe method for controlling a virtual object provided in the foregoingmethod embodiments.

In addition, an embodiment of the disclosure further provides a storagemedium. The storage medium is configured to store a computer program.The computer program is configured to perform the method for controllinga virtual object provided in the foregoing embodiments.

An embodiment of the disclosure further provides a computer programproduct including instructions. The instructions, when run on acomputer, cause the computer to perform the method for controlling avirtual object provided in the foregoing embodiments.

It is to be understood that “plurality of” mentioned in thisspecification means two or more. “And/or” describes an associationrelationship for associated objects and represents that threerelationships may exist. For example, A and/or B may represent thefollowing three cases: only A exists, both A and B exist, and only Bexists. The character “/” generally indicates an “or” relationshipbetween the associated objects.

A person of ordinary skill in the art would understand that all or someof the operations of the foregoing embodiments may be implemented byusing hardware, or may be implemented by a program instructing relevanthardware. The program may be stored in a computer-readable storagemedium. The storage medium may be a read-only memory (ROM), a magneticdisk, an optical disc, or the like.

The technical solutions provided in the embodiments of the disclosureachieve at least the following beneficial effects.

A target region is set in a UI for a user to perform a quick operationin the target region to control a virtual object to performcorresponding motions, so that without triggering UI controlscorresponding to the motions and without memorizing the functions andpositions of the UI controls, the user may control the virtual objectaccording to the quick operation to perform corresponding motions in avirtual environment.

At least one of the components, elements, modules or units describedherein may be embodied as various numbers of hardware, software and/orfirmware structures that execute respective functions described above,according to an exemplary embodiment. For example, at least one of thesecomponents, elements or units may use a direct circuit structure, suchas a memory, a processor, a logic circuit, a look-up table, etc. thatmay execute the respective functions through controls of one or moremicroprocessors or other control apparatuses. Also, at least one ofthese components, elements or units may be specifically embodied by amodule, a program, or a part of code, which contains one or moreexecutable instructions for performing specified logic functions, andexecuted by one or more microprocessors or other control apparatuses.Also, at least one of these components, elements or units may furtherinclude or implemented by a processor such as a central processing unit(CPU) that performs the respective functions, a microprocessor, or thelike. Two or more of these components, elements or units may be combinedinto one single component, element or unit which performs all operationsor functions of the combined two or more components, elements of units.Also, at least part of functions of at least one of these components,elements or units may be performed by another of these components,element or units. Further, although a bus is not illustrated in some ofblock diagrams, communication between the components, elements or unitsmay be performed through the bus. Functional aspects of the aboveexemplary embodiments may be implemented in algorithms that execute onone or more processors. Furthermore, the components, elements or unitsrepresented by a block or processing operations may employ any number ofrelated art techniques for electronics configuration, signal processingand/or control, data processing and the like.

The foregoing descriptions are merely example embodiments of thedisclosure, but are not intended to limit the disclosure. Anymodification, equivalent replacement, or improvement made within thespirit and principle of the disclosure shall fall within the protectionscope of the disclosure.

What is claimed is:
 1. A method for controlling a virtual obj ect,performed by a terminal, the method comprising: displaying a userinterface (UI), the UI comprising a virtual environment image and aninteractive panel region, the virtual environment image being an imagein which a virtual environment is observed; receiving a preset operationin a target region in the UI, the target region comprising a regionpertaining to the virtual environment image but not pertaining to theinteractive panel region; and controlling the virtual object accordingto the preset operation to perform a corresponding motion in the virtualenvironment.
 2. The method according to claim 1, wherein the controllingthe virtual object according to the preset operation comprises:controlling, based on a body posture of the virtual object meeting afirst condition, the virtual object according to the preset operation toadjust the body posture in the virtual environment.
 3. The methodaccording to claim 2, wherein the first condition comprises that thebody posture of the virtual object is in a squatting state; the presetoperation comprises a two-finger vertical swipe operation; and thecontrolling, based on the body posture of the virtual object meeting thefirst condition, the virtual object according to the preset operation toadjust the body posture in the virtual environment comprises: receivingthe two-finger vertical swipe operation in the target region; andcontrolling, based on the body posture of the virtual object being inthe squatting state, the virtual object according to the two-fingervertical swipe operation to switch from the squatting state to astanding state in the virtual environment.
 4. The method according toclaim 3, wherein the target region comprises a first target region and asecond target region; and the receiving the two-finger vertical swipeoperation in the target region comprises: obtaining first start positioncoordinates of a first contact point in the first target region andsecond start position coordinates of a second contact point in thesecond target region; obtaining, based on swiping of the first contactpoint and the second contact point being stopped, first end positioncoordinates of the first contact point in the first target region andsecond end position coordinates of the second contact point in thesecond target region; and determining, based on a vertical coordinatedisplacement of the first contact point being greater than a verticalcoordinate displacement threshold and a vertical coordinate displacementof the second contact point being greater than the vertical coordinatedisplacement threshold, that the two-finger vertical swipe operation isreceived in the target region.
 5. The method according to claim 1,wherein the controlling the virtual object according to the presetoperation comprises: controlling, based on a use state of a virtual itemmeeting a second condition, the virtual object according to the presetoperation to open an accessory corresponding to the virtual item in thevirtual environment; or controlling, based on the use state of thevirtual item meeting a third condition, the virtual object according tothe preset operation to start to use the virtual item in the virtualenvironment; or controlling, based on the use state of the virtual itemmeeting a fourth condition, the virtual object according to the presetoperation to throw the virtual item in the virtual environment.
 6. Themethod according to claim 5, wherein the second condition comprises thatthe virtual item is in an auto-start state; the preset operation furthercomprises a double-tap operation; and the controlling, based on the usestate of the virtual item meeting the second condition, the virtualobject according to the preset operation to open the accessorycorresponding to the virtual item in the virtual environment comprises:receiving the double-tap operation in the target region; andcontrolling, based on a first virtual item being in the auto-startstate, the virtual object according to the double-tap operation to opena sight corresponding to the first virtual item in the virtualenvironment.
 7. The method according to claim 6, wherein the receivingthe double-tap operation in the target region comprises: obtaining atime of a first tap operation and a time of a second tap operation inthe target region; and determining, based on a time interval between thefirst tap operation and the second tap operation being less than a timeinterval threshold, that the double-tap operation is received in thetarget region.
 8. The method according to claim 5, wherein the thirdcondition comprises that the virtual item is in a manual start state;the preset operation further comprises a double-tap and long-pressoperation; and the controlling, based on the use state of the virtualitem meeting the third condition, the virtual object according to thepreset operation to start to use the virtual item in the virtualenvironment comprises: receiving the double-tap and long-press operationin the target region; and controlling, based on a second virtual itembeing in the manual start state, the virtual object according to thedouble-tap and long-press operation to start to use the second virtualitem in the virtual environment.
 9. The method according to claim 8,wherein the receiving the double-tap and long-press operation in thetarget region comprises: receiving a press operation in the targetregion after a double-tap operation in the target region is received;and determining, based on a duration of the press operation beinggreater than a duration threshold, that the double-tap and long-pressoperation is received in the target region.
 10. The method according toclaim 8, wherein after the controlling, based on the second virtual itembeing in the manual start state, the virtual object according to thedouble-tap and long-press operation to start to use the second virtualitem in the virtual environment, the method further comprises:controlling, based on the double-tap and long-press operation in thetarget region being stopped, the virtual object to stop using thevirtual item.
 11. The method according to claim 5, wherein the fourthcondition comprises that the virtual object owns the virtual item; thepreset operation further comprises a two-finger horizontal swipeoperation; and the controlling, based on the use state of the virtualitem meeting the fourth condition, the virtual object according to thepreset operation to throw the virtual item in the virtual environmentcomprises: receiving the two-finger horizontal swipe operation in thetarget region; and controlling, based on the virtual object owning athird virtual item, the virtual object according to the two-fingerhorizontal swipe operation to throw the third virtual item in thevirtual environment.
 12. The method according to claim 11, wherein thetarget region comprises a first target region and a second targetregion; and the receiving the two-finger horizontal swipe operation inthe target region comprises: obtaining first start position coordinatesof a first contact point in the first target region and second startposition coordinates of a second contact point in the second targetregion; obtaining, based on swiping of the first contact point and thesecond contact point being stopped, first end position coordinates ofthe first contact point in the first target region and second endposition coordinates of the second contact point in the second targetregion; and determining, based on a horizontal coordinate displacementof the first contact point being greater than a horizontal coordinatedisplacement threshold and a horizontal coordinate displacement of thesecond contact point being greater than the horizontal coordinatedisplacement threshold, that the two-finger horizontal swipe operationis received in the target region.
 13. An apparatus for controlling avirtual object, comprising: at least one memory configured to storeprogram code; and at least one processor configured to read the programcode and operate as instructed by the program code, the program codecomprising: display code configured to cause the at least one processorto display a user interface (UI), the UI comprising a virtualenvironment image and an interactive panel region, the virtualenvironment image being an image in which a virtual environment isobserved; receiving code configured to cause the at least one processorto receive a preset operation in a target region in the UI, the targetregion comprising a region pertaining to the virtual environment imagebut not pertaining to the interactive panel region; and control codeconfigured to cause the at least one processor to control the virtualobject according to the preset operation to perform a correspondingmotion in the virtual environment.
 14. The apparatus according to claim13, wherein the control code is further configured to cause the at leastone processor to control, based on a body posture of the virtual objectmeeting a first condition, the virtual object according to the presetoperation to adjust the body posture in the virtual environment.
 15. Theapparatus according to claim 14, wherein the first condition comprisesthat the body posture of the virtual object is in a squatting state; thepreset operation comprises a two-finger vertical swipe operation; andwherein the control code is further configured to cause the at least oneprocessor to, based on receiving the two-finger vertical swipe operationin the target region and based on the body posture of the virtual objectbeing in the squatting state, control the virtual object according tothe two-finger vertical swipe operation to switch from the squattingstate to a standing state in the virtual environment.
 16. The apparatusaccording to claim 15, wherein the target region comprises a firsttarget region and a second target region; and the receiving code isfurther configured to cause the at least one processor to obtain firststart position coordinates of a first contact point in the first targetregion and second start position coordinates of a second contact pointin the second target region; obtain, based on swiping of the firstcontact point and the second contact point being stopped, first endposition coordinates of the first contact point in the first targetregion and second end position coordinates of the second contact pointin the second target region; and determine, based on a verticalcoordinate displacement of the first contact point being greater than avertical coordinate displacement threshold and a vertical coordinatedisplacement of the second contact point being greater than the verticalcoordinate displacement threshold, that the two-finger vertical swipeoperation is received in the target region.
 17. The apparatus accordingto claim 13, wherein the control code is further configured to cause theat least one processor to control, based on a use state of a virtualitem meeting a second condition, the virtual object according to thepreset operation to open an accessory corresponding to the virtual itemin the virtual environment; or controlling, based on the use state ofthe virtual item meeting a third condition, the virtual object accordingto the preset operation to start to use the virtual item in the virtualenvironment; or controlling, based on the use state of the virtual itemmeeting a fourth condition, the virtual object according to the presetoperation to throw the virtual item in the virtual environment.
 18. Theapparatus according to claim 17, wherein the second condition comprisesthat the virtual item is in an auto-start state; the preset operationfurther comprises a double-tap operation; and the control code isfurther configured to cause the at least one processor to control, basedon receiving the double-tap operation in the target region and based ona first virtual item being in the auto-start state, the virtual objectaccording to the double-tap operation to open a sight corresponding tothe first virtual item in the virtual environment.
 19. A computerdevice, comprising a processor and a memory, the memory storing at leastone instruction, at least one program, a code set, or an instructionset, the at least one instruction, the at least one program, the codeset, or the instruction set being loaded and executed by the processorto implement the method according to claim
 1. 20. A non-transitorystorage medium, configured to store a computer program, the computerprogram being executable by at least one processor to perform:displaying a user interface (UI), the UI comprising a virtualenvironment image and an interactive panel region, the virtualenvironment image being an image in which a virtual environment isobserved; receiving a preset operation in a target region in the UI, thetarget region comprising a region pertaining to the virtual environmentimage but not pertaining to the interactive panel region; andcontrolling a virtual object according to the preset operation toperform a corresponding motion in the virtual environment.